package com.zp.common.base.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.zp.common.base.entity.Role;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface RoleRepository extends BaseMapper<Role> {

    @Select("select name from t_role where id in (select role_id from t_role_auth where auth_id=#{id})")
    List<String> loadRoleByAuthInfoId(Long id);
}
